<?php
/**
 * $Id: external.php 7 2009-01-05 19:33:38Z gpo_gigapromoters $
 * 
 * This file can not be redistributed to anyone without the permission of Giga Promoters
 * Copyright 2005 - 2008, Giga Promoters
 * 						  608 Aggarwal Cyber Plaza
 *						  Netaji Subhash Place, Delhi - 110034
 *						  www.gigapromoters.com
 * 
 *
 * @version 			$Rev: 7 $
 * @lastModifiedBy		$LastChangedBy: gpo_gigapromoters $
 * @lastChanged			$Date: 2009-01-06 01:03:38 +0530 (Tue, 06 Jan 2009) $
 * @copyright 			Giga Promoters (www.gigapromoters.com)
 * 
 */

/**
 * External behavior used for dynamic model associations. No more in use.
 *
 */
class ExternalBehavior extends ModelBehavior {
	
	var $model;

	function setup(&$model) {

		$this->model = $model;
		
	}

	function beforeFind()
	{
		$this->model->bindModel(array('hasOne' => array(

					'Hit' => array('className' => 'Hits.Hit',
										'foreignKey' => 'item_id',
										'dependent' => false,
										'conditions' => 'Hit.type="'.$this->model->name.'"',
										'fields' => '',
										'order' => '',
										'limit' => '',
										'offset' => '',
										'exclusive' => '',
										'finderQuery' => '',
										'counterQuery' => ''
									))
						));


	}



	

	

}
?>